<template>
    <div class="kbl-header">
        <div class="kbl-header-contaier">
            <div class="back-box" @touchend='backPre'>
                <img src="~assets/icons/back.png" alt="" v-if="isChild">
            </div>
            <span>{{head}}</span>
        </div>
    </div>
</template>

<script>
export default {
    name:'kblHeader',
    data(){
        return {
            
        }
    },
    methods:{
        backPre(){
            this.$router.go(-1);
        }
    },
    computed:{
        head(){
            return this.$store.state.tab;
        },
        isChild(){
            return this.$route.meta.isChild
        }
    },
    mounted(){
        
    },
}
</script>

<style lang='less'>
@rem:100rem;

.kbl-header{
    z-index: 9999999;
    .kbl-header-contaier{
        width: 100%;
        height: 88/@rem;
        display: flex;
        align-items: center;
        justify-content: center;
        background: #fff;
        position: relative;
        z-index: 99999;
        border-bottom: 1px solid #cccccc;
        span{
            font-size: 36/@rem;
            color: #282828;
        }
        .back-box{
            width: 68/@rem;
            height: 88/@rem;
            position: absolute;
            left: 10/@rem;
            top: 0;
            text-align: center;
            line-height: 88/@rem;
            img{
                width: 20/@rem;
                height: 36/@rem;
                vertical-align: middle;
            }
        }
        
    }
}
</style>
